<?php

use App\Services\Utils\TimeHelper;
use Faker\Generator as Faker;

/** @var \Illuminate\Database\Eloquent\Factory $factory */
$factory->define(\App\Models\Coupon\CouponCard::class, function (Faker $faker) {
    
    return [
        'code'             => TimeHelper::microTimeSerial(),
        'wechat_user_id'   => 0,
        'coupon_ticket_id' => 0,
        'is_used'          => \App\Models\Coupon\CouponCard::NOT_USED,
        'started_at'       => now()->subDay(),
        'ended_at'         => now()->addDay(),
    ];
});
